<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>square-grid</title>
    <style>
        html,
        body {
            margin: 0;
            padding: 0;
            height: 100%;
            width: 100%;
        }

        #test {
            margin: 200px auto;
            text-align: center;
            width: 600px;
            height: 400px;
        }

        #test {
            border-right: 1px solid #aaaaaa40;
            border-bottom: 1px solid #aaaaaa40;
            background-image:
                linear-gradient(#aaaaaa40 1px, transparent 0),
                linear-gradient(90deg, #aaaaaa40 1px, transparent 0),
                linear-gradient(#aaa 1px, transparent 0),
                linear-gradient(90deg, #aaa 1px, transparent 0);
            background-size: 10px 10px, 10px 10px, 50px 50px, 50px 50px;
        }
    </style>
</head>

<body>
    <div id="test"></div>
</body>
</html>